from datetime import datetime
from itpay.core.sys.const import BulletinStatusType


def wrap_bulletin_info(bulletin_dict):
    now = datetime.now()
    bulletin_dict["status"] = BulletinStatusType.ENABLE.value if bulletin_dict['start_time'] <= now <= bulletin_dict[
        'end_time'] else BulletinStatusType.DISABLE.value

    return bulletin_dict
